package com.anpy.album.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;

import javax.persistence.Entity;
import javax.persistence.Id;
import java.util.Date;

@Entity
@Data
@TableName(value = "T_ALBUM")
public class AlbumEntity {

    @Id
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;
    @TableField(value = "album_name")
    private String albumName;
    @TableField(value = "album_cover")
    private String albumCover;
    private Integer shared;
    @TableField(value = "creator_id")
    private Integer creatorId;

    @TableField(value = "photo_size")
    private Integer photoSize;
    @TableField(value = "user_id")
    private Integer userId;
    @TableField(value = "create_at")
    private Date createTime;
    @TableField(value = "update_at")
    private Date updateTime;

    public void setId(Long id) {
        this.id = id;
    }

    public Long getId() {
        return id;
    }

}
